<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="https://cdn.bootcss.com/jquery/2.1.0/jquery.min.js"></script>
    <script type="text/javascript">
        function crosRequest() {
            $.ajax({
                url: 'https://api-dev.fts.aero:8443/cms/rest/video/categories',
                type: 'get',
                headers: {
                    Authorization: "Bearer 18ed4ba3-c025-4f48-8e37-ded9f4b38c2d",
                },
                success: function (data) {
                    console.log(data);
                }
            });
        }


         function crosRequest2z() {
            $.ajax({
                url: 'http://localhost:8600/setting/getFlightDetail?tailNum=1',
                type: 'get',
                headers: {
                    Authorization: "Bearer 3cb7ef55-acc4-48df-9f74-2a7509c610b9",
                },
                success: function (data) {
                    console.log(data);
                }
            });
        }



        function crosRequest2() {
            $.ajax({
                url: 'http://xop-web.fts.aero/home/flow-add',
                contentType: "application/json; charset=utf-8",
                type: 'post',
                dataType: 'json',
                headers: {
                    Authorization: "Bearer 7d21977d-77e6-46e0-bdc1-f0ba98b95bb3"
                },
                data: JSON.stringify({
                    "code": "string",
                    "description": "10元50m流量包",
                    "from": "2018-08-01 00:00:00",
                    "name": "string",
                    "offset": 0,
                    "offsetUnit": "13",
                    "ownerId": 1,
                    "price": 0,
                    "priority": 0,
                    "remarks": "string",
                    "stackNum": 0,
                    "termType": "1",
                    "to": "2018-08-31 23:59:59",
                    "validityBegin": "2018-09-10",
                    "validityEnd": "2018-09-10",
                    "value": 0
                }),
                success:

                    function (data) {
                        console.log(data);
                    }
            })
            ;
        }

    </script>
</head>
<body>
<button onclick="crosRequest()">请求跨域资源</button>
<button onclick="crosRequest2z()">请求跨域资源2</button>
<button onclick="crosRequest2()">Flow Add</button>
</body>
</html>